<select ng-model="ctrl.type" ng-model-options="{ debounce: 500 }" ng-change="ctrl.changeType(ctrl.type)" ng-disabled="ctrl.model.addressBook.readOnly">
	<option ng-repeat="option in ctrl.availableOptions" value="{{option.id}}">{{option.name}}</option>
</select>
<button ng-click="ctrl.deleteField()" class="icon-delete" title="{{ctrl.t.delete}}" ng-if="!ctrl.model.addressBook.readOnly"></button>
<div>

	<label for="details-pobox-{{ctrl.index}}">{{ctrl.t.poBox}}</label>
	<input type="text" id="details-pobox-{{ctrl.index}}" name="address" ng-model="ctrl.data.value[0]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()"  value=""
	ng-disabled="ctrl.model.addressBook.readOnly" />
</div>
<div>
	<label for="details-address-{{ctrl.index}}">{{ctrl.t.address}}</label>
	<input type="text" id="details-address-{{ctrl.index}}" name="address" ng-model="ctrl.data.value[2]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()" value=""
	ng-disabled="ctrl.model.addressBook.readOnly"
		   focus-expression="$parent.ctrl.focus === ctrl.name" />
</div>
<div>
	<label for="details-postal-code-{{ctrl.index}}">{{ctrl.t.postalCode}}</label>
	<input type="text" id="details-postal-code-{{ctrl.index}}" name="postal-code" ng-model="ctrl.data.value[5]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()" value=""
	ng-disabled="ctrl.model.addressBook.readOnly" />
</div>
<div>
	<label for="details-city-{{ctrl.index}}">{{ctrl.t.city}}</label>
	<input type="text" id="details-city-{{ctrl.index}}" name="city" ng-model="ctrl.data.value[3]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()" value=""
	ng-disabled="ctrl.model.addressBook.readOnly" />
</div>
<div>
	<label for="details-state-{{ctrl.index}}">{{ctrl.t.state}}</label>
	<input type="text" id="details-state-{{ctrl.index}}" name="state" ng-model="ctrl.data.value[4]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()" value=""
	ng-disabled="ctrl.model.addressBook.readOnly" />
</div>
<div>
	<label for="details-country-{{ctrl.index}}">{{ctrl.t.country}}</label>
	<input type="text" id="details-country-{{ctrl.index}}" name="state" ng-model="ctrl.data.value[6]" ng-model-options="{ debounce: 500 }" ng-change="ctrl.model.updateContact()" value=""
	ng-disabled="ctrl.model.addressBook.readOnly" />
</div>
